#ifndef FENETRE_H
#define FENETRE_H

#endif // FENETRE_H

#include <QApplication>
#include <QWidget>
#include <QUrl>
#include <QPushButton>
#include <QNetworkAccessManager>
#include <QLabel>
#include "horaire.h"
#include <QSystemTrayIcon>
#include <pref_window.h>
#include <QList>


class fenetre :  public QWidget

{
Q_OBJECT

public:
fenetre(QWidget *parent = 0);

private slots:

void quitter();
void show_pref();

int ChargerConf_Objets();
void Notification(QSystemTrayIcon::ActivationReason why_activated);
void TextToNotif(QString texte);
void set_lstring_by_id(int,QString);

protected:
void closeEvent(QCloseEvent *event);





private:
QLabel      *ligne;
QLabel      *direction_1;
QLabel      *direction_2;

QPushButton *btn_get;
QUrl        url_principale;
horaire     *_horaire;
QSystemTrayIcon *tray;
Pref_Window *pref_win;
bool isMovingWindow;

void readSettings();
void writeSettings();
QTimer *timer;
QList<horaire*> l_horaire;
QString l_string;

QString all_horaire;
int             id_lstring;
int             nbr_passage;
bool            is_refreshing;
bool            premier_passage;



};
